#include <stdio.h>
#include <stdlib.h>

void shellSort(int a[], int n) {
    int i, j, d;
    for (d = n / 2; d >= 1; d /= 2) {
        for (i = d + 1; i <= n; i++) {
            int temp = a[i];
            j = i;
            while (j > d && a[j - d] > temp) {
                a[j] = a[j - d];
                j -= d;
            }
            a[j] = temp;
        }
    }
}

int main() {
    int n, i, sum1 = 0, sum2 = 0;
    scanf("%d", &n);
    int a[n + 1];
    for (i = 1; i <= n; i++) {
        scanf("%d", &a[i]);
    }

    shellSort(a, n);

    for (i = 1; i <= n; i++) {
        if (i <= n / 2) {
            sum1 += a[i];
        } else {
            sum2 += a[i];
        }
    }

    if (n % 2 == 0) {
        printf("Outgoing #: %d\n", n / 2);
        printf("Introverted #: %d\n", n / 2);
        printf("Diff = %d\n", sum2 - sum1);
    } else {
        printf("Outgoing #: %d\n", n / 2 + 1);
        printf("Introverted #: %d\n", n / 2);
        printf("Diff = %d\n", sum2 - sum1);
    }

    return 0;
}
